﻿using SqlSugar;
using System;
using System.Collections.Generic;
using System.Linq;
using System.Threading.Tasks;

namespace XREditor.Models
{
    /// <summary>
    /// 最后一次操作的项目表
    /// </summary>
    [SugarTable("projecthistory", TableDescription = "最后一次操作的项目表")]
    public class ProjectHistory
    {
        /// <summary>
        /// 主键ID
        /// </summary>
        [SugarColumn(IsPrimaryKey = true, IsIdentity = true, ColumnName = "id", ColumnDescription = "主键ID")]
        public long Id { get; set; }

        /// <summary>
        /// 最后一次操作的项目ID
        /// </summary>
        [SugarColumn(ColumnName = "lastopid", ColumnDescription = "最后一次操作的项目ID")]
        public long LastOpId { get; set; } = 0;

        /// <summary>
        /// 创建时间
        /// </summary>
        [SugarColumn(ColumnName = "created", IsOnlyIgnoreUpdate = true)]
        public DateTime Created { get; set; } = DateTime.Now;

        /// <summary>
        /// 更新时间
        /// </summary>        
        [SugarColumn(ColumnName = "updated")]
        public DateTime Updated { get; set; } = DateTime.Now;

    }
}
